package com.arsn.myf.quartz.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import org.springframework.format.annotation.DateTimeFormat;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * 定时任务对象
 *
 * @author zhongrj
 * @date 2022-12-12 20:43:00
 */
@Data
@TableName("sys_scheduled_job")
@ApiModel(value = "ScheduledJob对象", description = "ScheduledJob对象")
public class ScheduledJob implements Serializable{

    private static final long serialVersionUID = 1L;

    /**
    * 
    */
    @TableId(value = "id",type = IdType.AUTO)
    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(value = "")
    private Integer id;

    /**
    * 任务名称
    */
    @ApiModelProperty(value = "任务名称")
    private String name;

    /**
    * 任务表达式
    */
    @ApiModelProperty(value = "任务表达式")
    private String cronExpression;

    /**
    *  描述,备注
    */
    @ApiModelProperty(value = " 描述,备注")
    private String remark;

    /**
    * 状态  1:正常  2:停止
    */
    @ApiModelProperty(value = "状态  1:正常  2:停止")
    private Integer status;

    /**
    * 创建时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    /**
    * 更新时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    /**
    * 方法名
    */
    @ApiModelProperty(value = "方法名")
    private String methodName;

    /**
    * spring bean 名称
    */
    @ApiModelProperty(value = "spring bean 名称")
    private String beanName;

    /**
    * 参数
    */
    @ApiModelProperty(value = "参数")
    private String params;

    /**
    * 最近执行时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(value = "最近执行时间")
    private Date activeTime;

}
